package com.dingup.paike.util;

import com.dingup.paike.bean.config.SysConfigData;

import java.util.HashMap;

/**
 * Created by yanggavin on 16/6/12.
 */
public class ConstUtil {
    /**
     * global
     */
    public final static String SYSTEM_START_UP_TIME = String.valueOf(System.currentTimeMillis());
    public final static String DEFAULT_ENCODE = "UTF-8";
    public final static String CONTENT_TYPE_JSON = "application/json";
    public final static String CONTENT_TYPE_APPLICATION_JSONP = "application/x-json";
    public final static String CONTENT_TYPE_URLENCODED = "application/x-www-form-urlencoded";
    public final static String CONTENT_TYPE_AUDIO_WAV = "audio/wav";
    public final static String STRING_EMPTY = "";
    public final static String STRING_BLANK = " ";
    public final static String STRING_COMMA = ",";
    public final static Integer INTEGER_ZERO = 0;
    public final static String WX_MC_IBT_SECRET_KEY = "sldjfFJLdjFjidDIJFL";
    public final static String LAST_ADD_LESSON_TIME = "LAST_ADD_LESSON_TIME";
    public final static SysConfigData SYS_CONFIG_DATA = SSpringFactory.getBean("sysConfigData");
    public final static HashMap<String, String> zoneAdminMap = new HashMap<>();
    public final static String CHINA_CODE = "86-";
    public final static  int CODE_STUDENT = 1;
    public final static  int CODE_OBSERVER = 2;
    public final static  String DEFAULT_FOLDER_ID = "0";
    /**
     * response code
     */
    public final static Integer RESPONSE_CODE_SUCCESS = 200;
    public final static Integer RESPONSE_CODE_ERROR = 501;
    /**
     * EEO controller
     */
    public final static String EEO_GET_COURSE_LIST = "getCourseList";
    public final static String EEO_ADD_COURSE = "addCourse";
    public final static String EEO_EDIT_COURSE = "editCourse";
    public final static String EEO_DEL_COURSE = "delCourse";
    public final static String EEO_GET_COURSE_CLASS = "getCourseClass";
    public final static String EEO_ADD_COURSE_CLASS_MULTIPLE = "addCourseClassMultiple";
    public final static String EEO_ADD_COURSE_CLASS = "addCourseClass";
    public final static String EEO_EDIT_COURSE_CLASS = "editCourseClass";
    public final static String EEO_DEL_COURSE_CLASS = "delCourseClass";
    public final static String EEO_GET_COURSE_STUDENT = "getCourseStudent";
    public final static String EEO_ADD_COURSE_STUDENT = "addCourseStudent";
    public final static String EEO_DEL_COURSE_STUDENT = "addCourseStudent";
    public final static String EEO_GET_COURSE_INFO = "getCourseInfo";
    public final static String EEO_GET_CLASS_INFO = "getClassInfo";
    public final static String EEO_REGISTER = "register";
    public final static String EEO_ADD_COURSE_STUDENT_MULTIPLE = "addCourseStudentMultiple";
    public final static String EEO_DEL_COURSE_STUDENT_MULTIPLE = "delCourseStudentMultiple";
    public final static String EEO_ADD_CLASS_STUDENT_MULTIPLE = "addClassStudentMultiple";
    public final static String EEO_DEL_CLASS_STUDENT_MULTIPLE = "delClassStudentMultiple";
    public final static String EEO_MODIFY_PASSWORD = "modifyPasswaord";
    public final static String EEO_GET_STUDENT_LIST = "getStudentList";
    public final static String EEO_GET_TEACHER_LIST = "getTeacherList";
    public final static String EEO_ADD_TEACHER = "addTeacher";
    public final static String EEO_ADD_TEACHER_BY_EMAIL = "addTeacherByEmail";
    public final static String EEO_EDIT_TEACHER = "editTeacher";
    public final static String EEO_GET_TEMP_LOGIN_KEY = "getTempLoginKey";
    public final static String EEO_GET_LOGIN_LINKED = "getLoginLinked";
    public final static String EEO_GET_CLASS_MEMBER_TIME = "getClassMemberTime";
    public final static String EEO_GET_FOLDER_LIST = "getFolderList";
    public final static String EEO_MODIFY_PASSWORD_BY_TELEPHONE = "modifyPasswordByTelephone";
    public final static String EEO_SET_CLASS_VIDEO_MULTIPLE = "setClassVideoMultiple";
    public final static String EEO_GET_CLASS_VIDEO = "getClassVideo";
    public final static String EEO_GET_WEB_CAST_URL = "getWebcastUrl";
    public final static String EEO_MODIFY_CLASS_SEAT_NUM = "modifyClassSeatNum";
    /**
     * request parameter
     */
    public final static String PARAM_LESSON_ID = "lessonId";
    public final static String REQUEST_PARAMETER_IS_RESET_PASSWORD = "is_reset_password";
    public final static String REQUEST_PARAMETER_ID = "id";
    public final static String REQUEST_PARAMETER_TIME_STAMP = "time_stamp";
    public final static String REQUEST_PARAMETER_TEACHER_ACCOUNT = "teacher_account";
    public final static String REQUEST_PARAMETER_TEACHER_NAME = "teacher_name";
    public final static String REQUEST_PARAMETER_USER_MOBILE_PHONE = "user_mobile_phone";
    public final static String REQUEST_PARAMETER_USER_ID = "user_id";
    public final static String REQUEST_PARAMETER_USER_PASSWORD = "user_password";
    public final static String REQUEST_PARAMETER_OLD_PASSWORD = "old_password";
    public final static String REQUEST_PARAMETER_NEW_PASSWORD = "new_password";
    public final static String REQUEST_PARAMETER_USER_NAME = "user_name";
    public final static String REQUEST_PARAMETER_USER_ROLE = "user_role";
    public final static String REQUEST_PARAMETER_USER_ZONE = "user_zone";
    public final static String REQUEST_PARAMETER_USER_EMAIL = "user_email";
    public final static String REQUEST_PARAMETER_CREATE_TIME = "create_time";
    public final static String REQUEST_PARAMETER_EEO_LESSON_ID = "eeo_lesson_id";
    public final static String REQUEST_PARAMETER_LESSON_NAME = "lesson_name";
    public final static String REQUEST_PARAMETER_LESSON_ID = "lesson_id";
    public final static String REQUEST_PARAMETER_IS_BATCH_DEL = "is_batch_del";
    public final static String REQUEST_PARAMETER_UID = "uid";
    public final static String REQUEST_PARAMETER_MONTh = "month";
    public final static String REQUEST_PARAMETER_BEGIN_TIME = "begin_time";
    public final static String REQUEST_PARAMETER_END_TIME = "end_time";
    public final static String REQUEST_PARAMETER_VIDEO_OPTION = "video_option";
    public final static String REQUEST_PARAMETER_TEACHER_USER_ID = "teacher_user_id";
    public final static String REQUEST_PARAMETER_CLASS_ID = "class_id";
    public final static String REQUEST_PARAMETER_CLASS_IDS = "class_ids";
    public final static String REQUEST_PARAMETER_CLASS_NAME = "class_name";
    public final static String REQUEST_PARAMETER_CLASS_ZONE = "class_zone";
    public final static String REQUEST_PARAMETER_SYNC_EEO = "sync_eeo";
    public final static String REQUEST_PARAMETER_EEO_COURSE_ID = "eeo_course_id";
    public final static String REQUEST_PARAMETER_EEO_COURSE_NAME = "eeo_course_name";
    public final static String REQUEST_PARAMETER_EEO_FOLDER_ID = "eeo_folder_id";
    public final static String REQUEST_PARAMETER_EXPIRED_TIME = "expired_time";
    public final static String REQUEST_PARAMETER_COURSE_STATUS = "course_status";
    public final static String REQUEST_PARAMETER_PAGE = "page";
    public final static String REQUEST_PARAMETER_COLOR = "color";
    public final static String REQUEST_PARAMETER_FOLDER_ID = "folder_id";
    public final static String REQUEST_PARAMETER_STUDENT_IDS = "student_ids";
    public final static String REQUEST_PARAMETER_TEACHER_IDS = "teacher_ids";
    public final static String REQUEST_PARAMETER_STUDENT_INFOS = "student_infos";
    public final static String REQUEST_PARAMETER_HEAD_TEACHER_USER_ID = "head_teacher_user_id";
    public final static String REQUEST_PARAMETER_START_TIME = "start_time";
    public final static String REQUEST_PARAMETER_LESSON_DATE = "lesson_date";
    public final static String REQUEST_PARAMETER_OBSERVER_USER_IDS = "observer_user_ids";
    public final static String REQUEST_PARAMETER_USER_TOKEN = "user_token";
    public final static String REQUEST_PARAMETER_IS_USER_AUTHORIZE = "is_user_authorize";
    public final static String REQUEST_PARAMETER_OPEN_ID = "open_id";
    public final static String REQUEST_PARAMETER_SECURITY_TOKEN = "security_token";
    public final static String REQUEST_PARAMETER_TYPE = "type";
    public final static String REQUEST_PARAMETER_CLASS_FEE = "class_fee";
    public final static String REQUEST_PARAMETER_LESSONS_STR = "lessons_str";
    public final static String REQUEST_PARAMETER_NOTIFY_DATE_STR = "notify_date_str";
    public final static String REQUEST_PARAMETER_NOTIFY_TYPE = "notify_type";
    public final static String REQUEST_PARAMETER_BATCH_CODE = "batch_code";
    public final static String REQUEST_PARAMETER_E_ID = "e_id";
    public final static String REQUEST_PARAMETER_CMD = "Cmd";
    public final static String REQUEST_PARAMETER_SID = "SID";
    public final static String REQUEST_PARAMETER_SAFE_KEY = "SafeKey";
    public final static String REQUEST_PARAMETER_TIMESTAMP = "TimeStamp";
    public final static String REQUEST_PARAMETER_MSG = "Msg";
    public final static String REQUEST_PARAMETER_ATTENDANCES = "attendances";
    public final static String REQUEST_PARAMETER_USERID = "userId";
    public final static String REQUEST_PARAMETER_WXID = "wxId";
    public final static String REQUEST_PARAMETER_OPENID = "openId";
    public final static String REQUEST_PARAMETER_NICKNAME = "nickName";
    public final static String REQUEST_PARAMETER_HEADIMGURL = "headImgUrl";
    public final static String REQUEST_PARAMETER_UNIONID = "unionId";
    public final static String REQUEST_PARAMETER_EXAM_TYPE = "exam_type";
    public final static String REQUEST_PARAMETER_SUBJECT_TYPE = "subject_type";
    public final static String REQUEST_PARAMETER_CLASS_TYPE = "class_type";
    public final static String REQUEST_PARAMETER_TEMPLATE_TYPE = "template_type";
    public final static String REQUEST_PARAMETER_STUDENT_ID = "student_id";
    public final static String REQUEST_PARAMETER_FEEDBACK = "feedback";
    /**
     * session
     */
    public final static String SESSION_ITEM_TS_USER_INFO = "session_item_ts_user_info";
    public final static String SESSION_USER_BASE_INFO_FOR_LOGGER = "session_user_base_info_for_logger";
    public final static String SESSION_USER_ID_INFO = "session_user_id_info";
    public final static Integer SESSION_KEEP_EXPIRED_SECOND = 60 * 60 * 24; // 24小时
    public final static String SESSION_RSA_KEY = "SESSION_RSA_KEY";
    /**
     * dao param name
     */
    public final static String KEY_SID = "SID";
    public final static String KEY_SAFE_KEY = "safeKey";
    public final static String KEY_TIME_STAMP = "timeStamp";
    public final static String KEY_COURSE_NAME = "courseName";
    public final static String MAPPER_PARAM_COURSE_STATUS = "courseStatus";
    public final static String MAPPER_PARAM_PAGE = "page";
    public final static String MAPPER_PARAM_PER_PAGE = "perpage";
    public final static String KEY_FOLDER_ID = "folderId";
    public final static String KEY_FILE_DATA = "Filedata";
    public final static String KEY_EXPIRY_TIME = "expiryTime";
    public final static String KEY_COURSE_ID = "courseId";
    public final static String KEY_BEGIN_TIME = "beginTime";
    public final static String KEY_CLASS_JSON = "classJson";
    public final static String KEY_END_TIME = "endTime";
    public final static String KEY_TEACHER_ACCOUNT = "teacherAccount";
    public final static String KEY_TEACHER_NAME = "teacherName";
    public final static String KEY_CLASS_ID = "classId";
    public final static String KEY_CLASS_NAME = "className";
    public final static String KEY_IDENTITY = "identity";
    public final static String MAPPER_PARAM_STUDENT_ACCOUNT = "studentAccount";
    public final static String MAPPER_PARAM_STUDENT_NAME = "studentName";
    public final static String KEY_STUDENT_JSON = "studentJson";
    public final static String MAPPER_PARAM_STUDENT_ARRAY = "studentArray";
    public final static String KEY_ACCOUNT = "account";
    public final static String KEY_NAME = "name";
    public final static String KEY_IS_REGISTER = "isRegister";
    public final static String KEY_TELEPHONE = "telephone";
    public final static String KEY_PASSWORD = "password";
    public final static String MAPPER_PARAM_MD5PASS = "md5pass";
    public final static String MAPPER_PARAM_OLD_MD5PASS = "oldMd5pass";
    public final static String MAPPER_PARAM_STUDENT_ID = "studentId";
    public final static String MAPPER_PARAM_TEACHER_EMAIL = "teacherEmail";
    public final static String MAPPER_PARAM_ST_ID = "st_id";
    public final static String MAPPER_PARAM_LIFE_TIME = "lifeTime";
    public final static String KEY_DATA = "data";
    public final static String KEY_ERROR_INFO = "error_info";
    public final static String KEY_ERRNO = "errno";
    public final static String KEY_ERROR = "error";
    public final static String MAPPER_PARAM_CLIENT_COURSE_ID = "client_course_id";
    public final static String MAPPER_PARAM_CLIENT_CLASS_ID = "client_class_id";
    public final static String KEY_SCHOOL_ID = "schoolId";
    public final static String KEY_AUTH_TICKET = "authTicket";
    public final static String KEY_RECORD = "record";
    public final static String KEY_LIVE = "live";
    public final static String KEY_REPLAY = "replay";
    public final static String KEY_SEAT_NUM = "seatNum";
    public final static String MAPPER_PARAM_CODE = "code";
    public final static String MAPPER_PARAM_RESULT = "result";
    /**
     * ibt key && wechat
     */
    public final static String MC_WX_ACCESS_TOKEN_KEY = "MC_WX_ACCESS_TOKEN_KEY";
    public final static Integer MC_WX_ACCESS_TOKEN_EXPIRY_SECOND = 60 * 60 * 2;
    public final static String MC_WX_JS_API_TICKET_KEY = "MC_WX_JS_API_TICKET_KEY";
    public final static Integer MC_WX_JS_API_TICKET_EXPIRY_SECOND = 60 * 60 * 2;
    public final static String WX_URL_SEND_TEMPLATE_MESSAGE = "https://api.weixin.qq.com/cgi-bin/message/template/send?access_token=";
    public final static String DATE_TIME_ZERO = "00:00:00";
    public static final String TIME_GO_TO_WORK = "06:00:00";
    public static final String TIME_OFF_DUTY = "23:59:00";
    public static final String TIME_REST_BEGIN = "13:00:00";
    public static final String TIME_REST_END = "14:00:00";

    static {
        zoneAdminMap.put("shanghai", "oA7Lgv2vXSNYKpTeN5Q3OsidtUP0"); // 周蔺
        zoneAdminMap.put("nanjing", "oA7Lgvwg9FobX_VdnjxWbWG7Iiyw"); // 张敏
        zoneAdminMap.put("zongbu", "oA7Lgv50NQI_UwxJ1NgH_VWFurV8");  // 瑞敏
    }
}











